<?php if(!IS_AJAX){?>
<include file="Public:header" />
<style>
.sourceInput { max-width: 60px; margin-bottom: 5px; }
.sourcePanel { text-align: center; position: absolute; top: 30px; background: #fafafa; border: 1px solid #ddd; padding: 5px; display: none; z-index: 3; min-width: 110px; }
.missionform { box-shadow: 0; }
.formBox { min-height: 40px; }
.checkoutform .form-inline { position: relative; padding-left: 10px; }
.checkoutform .checkbox-inline { padding-top: 9px; }
.checkoutform .form-inline .groupName { min-width: 80px; border-right: 1px dotted; padding-right: 5px; }
.checkoutform .form-inline:nth-child(2n) { background-color: rgba(0,0,0,0.25); color: #fff; }
.checkoutform .form-inline:nth-child(2n-1) { background-color: rgba(0,0,0,0.02); }
.checkoutform .cover { width: 100%; height: 100%; display: none; background: rgba(0,0,0,0.2); position: absolute; top: 0; left: 0; }
.checkoutform .sourceEdit { outline: 1px dashed; outline-offset: -6px; transition: all 0.2s ease-in-out; }
.checkoutform .sourceEdit:hover { background: rgba(0,0,0,0.03); outline-style: dotted; }
.groupName { border-right: none!important; }
.table-bordered td, .table-bordered th { border-left: none !important; border-right: none !important; }
.panel-extended { position: absolute; bottom: 0; left: 0; padding: 10px; background: #fff; display: none; width: 100%; border-top: 1px solid #999; }
.sourcePanel .pull-left { color: #7a7676; }
.cover { height: 100%; width: 100%; position: absolute; background: rgba(0,0,0,0.3); display: none; bottom: 0; right: 0; }
.hiddentop { padding-top: 0 !important; }
.formBox.a { background: url(__PUBLIC__/a.png) no-repeat center center; background-size: 50% auto; min-height: 200px; }
.formBox.p { background: url(__PUBLIC__/p.png) no-repeat center center; background-size: 50% auto; min-height: 200px; }
.selectlist { margin: 0; padding: 0; }
.selectlist ul { padding: 0 }
.selectlist li { list-style-type: none; margin: 0; padding: 0; padding: 5px; border-bottom: 1px solid #eee; margin: 0 8px; }
.selectlist li:hover { background: #eee; }
</style>
<div class="row" style="margin-top:-15px">
    <div class="col-sm-12" style="padding-top:0;">
        <div>
            <div class="panel affixelement" style="margin-bottom:15px;z-index:3;"  afftop="0" >
                <div style="padding:15px">
                    <div class="icheck">
                        <form action="<?php echo U('index');?>" id="ajaxlistboxform" style="background:#fff; ">
                            <input type="hidden" name="state" value="all">
                            <input type="hidden" name="type" value="1">
                            <div class="pull-left" style="line-height:34px; padding-top:5px;" id="missioncountbox">
                            </div>
                            <div class="btn-group" style="padding-top:5px;">
                                <button data-toggle="dropdown" class="btn btn-default dropdown-toggle" type="button">选择时间<span class="caret"></span></button>
                                <ul role="menu" class="dropdown-menu">
                                    <li style="white-space:nowrap" class="row">
                                        <div class="col-xs-12 text-center">
                                            <input class="form-control datepicker" id="starttime" name="starttime" readonly style="cursor:pointer; width:120px; display:inline;height:35px" value="<?php echo $sttime; ?>" placeholder="起始时间" type="text">
                                            至
                                            <input class="form-control datepicker" id="endtime" name="endtime" readonly style="cursor:pointer; width:120px; display:inline;" value="<?php echo $edtime; ?>" placeholder="结束时间" type="text">
                                        </div>
                                    </li>
                                </ul>
                            </div>
                            <div class="input-group" style="width:200px; padding-top:5px;">
                                <input type="text" style="height:35px;" name="keywords" value="<?php echo $keywords; ?>"  placeholder="审批名称或姓名" class="form-control">
                                <span class="input-group-btn">
                                <button type="submit" class="btn btn-default" style="height:35px"><i class="fa icon-search"></i></button>
                                </span>
                            </div>
                            <html:dropdownselect class="typeselect" selected="" name="type" style="height:30.99px; width:200px; margin-top:5px;" multi="0" action="{:U('Team/form')}" title="选择审批分类"  placeholder="点击选择审批分类"  listloaded="listloaded" />
                            <div id="reselectlayout" style="top:0; display:none; left:0; bottom:0; right:0; position:fixed; z-index:4999;">
                            </div>
                            <div id="ajaxlistboxboc" style="display:none;">
                                <a href="##" class="btn btn-info" id="ajaxlistboxsa">
                                    全选
                                </a>
                                <a href="##" class="btn btn-info" id="ajaxlistboxca">
                                    全不选
                                </a>
                                <a href="##" class="btn btn-info" id="ajaxlistboxsar">
                                    反选
                                </a>
                                <a rel="{:U('pass')}" href="##" class="btn btn-success">
                                    通过
                                </a>
                            </div>
                            <!-- 右边 -->
                            <div class="btn-group pull-right" style="padding-top:5px;">
                                <button data-toggle="dropdown" class="btn btn-default dropdown-toggle" type="button"><i class="fa icon-th"></i>
                                <span class="caret"></span></button>
                                <ul id="listcheck" role="menu" class="dropdown-menu">
                                    <li>
                                        <a onclick="location.href='{:U('index',['type'=>'0'])}'" href="javascript:void(0);">
                                            <i class="fa icon-list "></i> 列表视图
                                        </a>
                                    </li>
                                    <li>
                                        <a onclick="location.href='{:U('index',['type'=>'1'])}'" href="javascript:void(0);">
                                            <i class="fa icon-th"></i> 表格视图
                                        </a>
                                    </li>
                                </ul>
                            </div>
                            <!-- 右边结束 -->
                            <input type="hidden" name="pagesize" id="pagesize"/>
                            <div style="float:none; clear:both;">
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
        <form id="missioncountboxform" action="{:U('missioncount')}">
        </form>
    </div>
</div>
<div>
    <div class="panel">
        <div class="panel-heading" style="line-height:34px;">
            <span class="pagetitle">审批管理</span>
            <select class="form-control f-pagesize pull-right" name="pagesize" style="width:auto;" onchange="">
                <option value="10"
                
                <eq name="pagesize" value="10">selected="selected"</eq>
                >每页10条
                
                </option>
                <option value="25"
                
                <eq name="pagesize" value="25">selected="selected"</eq>
                >每页25条
                
                </option>
                <option value="50"
                
                <eq name="pagesize" value="50">selected="selected"</eq>
                >每页50条
                
                </option>
                <option value="100"
                
                <eq name="pagesize" value="100">selected="selected"</eq>
                >每页100条
                
                </option>
            </select>
            <div class="clearfix">
            </div>
        </div>
        <div class="panel-body">
            <div id="masonrybox1">
            </div>
            <div id="ajaxlistbox" class="hidden">
                <?php    }?>
                <?php if(IS_AJAX){?>
                
                <!-- 数据主体 -->
                <volist name="list" id="vo">
                    <div class="box col-sm-6 col-lg-6 col-hg-4 missionform" style="" <eq name="key" value="0">data-position="right" data-intro="这里处理审批文件的地方，每一个就是一个待审批的文案，里面展示了该审批的内容，你可以快速的预览并且做出判断，之后通过下面的【通过】【驳回】按钮快速完成审批工作，系统后台会将结果通知到申请人"</eq>>
                    <div class="panel panel-mission" style="margin:5px 0; position:relative; box-shadow: 2px 2px 5px #aaa; border-radius:0; border:1px solid #ccc; padding:15px;">
                        <!--{$html.$i}-->
                        <div class="BatchOperation BatchOperationBtn">
                            <input class="checkbox" type="checkbox" name="id[]" value="{$vo.id}">
                            <i class="fa icon-check"></i>
                            <div class="fabg"></div>
                        </div>
                        <h4 class="panel-heading">{$vo.title}</h4>
                        <div class="formBox <eq name="vo['state']" value="0">
                            a
                            </eq>
                            <eq name="vo['state']" value="3">p</eq>
                            " id="formBox-{$vo.id}">{:replacebr($vo['formtemplateText'])}
                        </div>
                        <h4 class="panel-heading">审批意见</h4>
                        <div class="schedulebox" id="schedulebox-{$vo.id}">
                            <notempty name="vo['schedule']">
                                <volist name="vo['schedule']" id="s">
                                    <p>
                                        <span class="">审批人：{$s.membername}</span>
                                        <eq name="s['status']" value="0"> 　<span class="label label-danger">驳回</span>
                                        </eq>
                                        <eq name="s['status']" value="1"> 　<span class="label label-success">通过</span>
                                        </eq>
                                        <gt name="s['sendParent']" value="0"><span class="label label-info">已递交上级</span></gt>
                                        <span class="pull-right">{:date('Y-m-d', $s['datatime'])}</span>
                                    <div class="clearfix">
                                    </div>
                                    </p>
                                    <p> 
                                        <b>意见：</b>
                                        <notempty name="s['comment']">{$s.comment}
                                            <else/>
                                            无 
                                        </notempty>
                                    </p>
                                    <gt name="s['ticketnum']" value="0">
                                        <p>
                                            获得奖票:<span style="color:#f60;">{$s.ticketnum}</span>张
                                            <volist name="s['integrals']" id="rvo">
                                                &nbsp;&nbsp;获得{$InteTypeList[$rvo['type']]}：<span style="color:#f60; font-weight:bold;">{:intval($rvo.num)}</span>张 </volist>
                                        </p>
                                    </gt>
                                </volist>
                                <else/>
                                <div style="padding:5px; text-align:center;">
                                    暂无审批记录
                                </div>
                            </notempty>
                        </div>
                        <!--<p>由【{$vo.approvername}】审批</p>-->
                        <!--<a class="btn btn-extended pull-right" href="javascript:void(0);"><i class="fa icon-chevron-down"></i></a> <br/><br/>-->
                        
                        <!--展开，收缩控制窗口开始-->
                        <div class="cover"></div>
                        <div class="panel-extended">
                            <div id="schedulebox-{$vo.id}pages">
                            </div>
                            <div id="passform-{$vo.id}-integral">
                                <if condition="$vo['integral']">
                                    <table class="table table-bordered" style="border:1px solid #ccc; margin-bottom:10px;">
                                        <thead bgcolor="#F7F7F7">
                                            <tr>
                                                <th width="80">姓名</th>
                                                <th>奖票</th>
                                                <volist name="vo['integral']" id="rvo">
                                                    <volist name="rvo['integral']" id="ivo">
                                                        <th>{$InteTypeList[$key]}</th>
                                                    </volist>
                                                </volist>
                                            </tr>
                                        </thead>
                                        <volist name="vo['integral']" id="rvo">
                                            <assign name="midk" value="$key" />
                                            <tr>
                                                <td style="line-height:34px;">{$rvo.name}</td>
                                                <td><input class="form-control" type="number" name="ticket" value="{:intval($userInfo['tiketnum'])}" min="0"></td>
                                                <volist name="rvo['integral']" id="ivo">
                                                    <td style="line-height:34px;">
                                                        <input class="form-control" type="hidden" name="integralmember_id[]" value="{$midk}">
                                                        <if condition="$giveintegral">
                                                            <input class="form-control" type="number" name="integralnum[]" value="{$ivo}">
                                                            <else/>
                                                            {$ivo}
                                                            <input class="form-control" type="hidden" name="integralnum[]" value="{$ivo}">
                                                        </if>
                                                        <input class="form-control" type="hidden" name="integraltype[]" value="{$key}">
                                                    </td>
                                                </volist>
                                            </tr>
                                        </volist>
                                    </table>
                                </if>
                            </div>
                            <form id="schedulebox-{$vo.id}form" action="{:U('schedule', array('id' => $vo['id']))}"></form>
                            <div class="panel" style="border:1px solid #ccc; margin-bottom:0;">
                                <!--添加界面引导 -->
                                <form id="passform-{$vo.id}" action="{:U('pass')}">
                                    <div id="passform-{$vo.id}-integralbox" class="hidden">
                                    </div>
                                    <textarea class="form-control input-lg p-text-area" name="comment" rows="2" placeholder="填写意见">{$vo.myschedule.comment}</textarea>
                                    <input type="hidden" value="0" name="status">
                                    <input type="hidden" name="mission_id" value="{$vo['id']}">
                                </form>
                                <footer class="panel-footer" style="padding:5px;">
                                    <ul class="nav nav-pills p-option">
                                        <li style="line-height:30px; width:100%;"> 申请人：{$vo['proposername']}
                                            <gt name="memberInfo['pid']" value="0">
                                                <button onClick="passform{$vo.id}(2);" class="btn btn-danger btn-sm pull-right">递交上级</button>
                                            </gt>
                                            <button style="margin-right:5px;" onClick="passform{$vo.id}(1);" class="btn btn-post btn-sm pull-right" >通过</button>
                                            <button style="margin-right:5px;" class="btn btn-default btn-sm pull-right" onClick="passform{$vo.id}(0);" >驳回</button>
                                        </li>
                                    </ul>
                                </footer>
                                <script>
                                        function passform{$vo.id}(status){
                                            var sendinput = '<input type="hidden" name="send" value="1">';
                                            $('#passform-{$vo.id} input[name="send"]').remove();
                                            if(status == 2){
                                                status = 1;
                                                $('#passform-{$vo.id}').append(sendinput);
                                            }
                                            $('#schedulebox-{$vo.id}').click();
                                            $('#passform-{$vo.id}').find('input[name="status"]').val(status);
                                            $('#passform-{$vo.id}-integral').find('input[type="number"]').each(function(index, element) {
                                                $(this).attr('value', $(this).val());
                                            });
                                            $('#passform-{$vo.id}-integralbox').html($('#passform-{$vo.id}-integral').html());
                                            //return false;
                                            //$('#passform-{$vo.id}').find('input[name="ticket"]').val($('#passform-{$vo.id}-integral').find('input[name="ticket"]').val());
                                            var data = $('#passform-{$vo.id}').serialize();
                                            $.ajax({
                                                url:$('#passform-{$vo.id}').attr('action'),
                                                data:data,
                                                type:'POST',
                                                dataType:"json",
                                                success: function(ret){
                                                    //失败则发出提醒信息
                                                    if(ret.status==0){
                                                        $.ThinkBox.error(ret.info,{'delayClose':500,modal:false, 'close': '关闭',x:0,y:0,center:false,locate:['left','top'], show:['',0]});
                                                    }
                                                    //如果没有表格则弹窗填写表格
                                                    if(ret.status == 2){
                                                        _openWindow('{:U('choiceForm') }&'+data, 500, '选择表格', '确认', function(){ passform{$vo.id}(status)}, '');
                                                    }
                                                    //成功了
                                                    if(ret.status == 1){
                                                        //document.getElementById('passform-{$vo.id}').reset();
                                                        
                                                        $('#schedulebox-{$vo.id}form').trigger('submit');
                                                        if(ret.state == 3){
                                                            //$('#formBox-{$vo.id}').css('background-size','100% auto');
                                                            $('#formBox-{$vo.id}').removeClass('a');
                                                            $('#formBox-{$vo.id}').addClass('p');
                                                        }
                                                        if(ret.state == 0){
                                                            //$('#formBox-{$vo.id}').css('background-size','100% auto');
                                                            $('#formBox-{$vo.id}').removeClass('p');
                                                            $('#formBox-{$vo.id}').addClass('a');
                                                        }
                                                        if(ret.state==2){
                                                            $('#formBox-{$vo.id}').removeClass('p').removeClass('a');
                                                        }
                                                        
                                                        //$('#formBox-{$vo.id}').css('background-size','50% auto');
                                                        setTimeout(function(){
                                                            window.$maso.masonry('reload');
                                                            /*//更新单个记录，并调用masonry的方法删除，添加，调整布局
                                                            $.get('{:U('getOne')}', { id:{$vo.id} }, function(data){
                                                                //alert(data.tbody);
                                                                $('#formBox-{$vo.id}').click().parents(".missionform");
                                                                window.$maso.masonry('remove',$('#formBox-{$vo.id}').parents('.missionform'))
                                                                            .masonry('reload');
                                                                $('#masonrybox1').append(data.tbody);
                                                                $('#formBox-{$vo.id}').parents('.missionform');
                                                                window.$maso.masonry( 'appended', $('#formBox-{$vo.id}').parents('.missionform'), true);
                                                                //绑定扩展窗口弹出事件和清除事件冒泡
                                                                $('#formBox-{$vo.id}').parents(".panel-mission").click(extended).find(".panel-extended").click(function(e) {
                                                                    e.stopPropagation();
                                                                });
                                                                //文本化新的表单
                                                                textualization($('#formBox-{$vo.id}'));
                                                            }, 'json');
                                                            //updatemasonry();
                                                            //$('#missioncountboxform').submit();
                                                            //$('#ajaxlistboxform').submit();*/
                                                        },100);
                                                    }
                                                }
                                            });
                                        }
                                    </script>
                            </div>
                        </div>
                        <!--控制窗口结束-->
                    </div>
                </div>
            
            <!-- 数据主体结束 -->
            </volist>
            <?php }?>
            <?php if(!IS_AJAX){?>
        </div>
        <div id="ajaxlistboxpages" class="pagesBox text-center">
            <?php echo $pages;?>
        </div>
    </div>
</div>
</div>
</div>
<include file="Public:script" />
<script src="__PUBLIC__/Js/jquery.masonry.min.js"></script>
<script>
    function listloaded(){
        $('.typeselect').blur(function(){
            $("#ajaxlistboxform input[name='formcategory_id']").remove();
            if($('div.typeselect span.itemspan').children("input:eq(1)").length!=0){
                $('#ajaxlistboxform').append("<input type='hidden' name='formcategory_id' value='"+$('.typeselect .itemspan').children("input:eq(1)").attr('value')+"'>");
            }
			 $('#masonrybox1').masonry('destroy').empty();
            $('#ajaxlistboxform').submit();
        });
    }
    function mission_send(id,e){
        if(!confirm('确定递交吗？')){
            return false;
        }
        hideLayer();
        $.post('{:U('send')}', {id:id}, function(data){
            if(data.status == 1){
                $('#ajaxlistboxform').submit();
                //updateList();
            }else{
                alert(data.info);
            }
        }, 'json');
    }
    function mission_cancel(id,e){
        if(!confirm('确定取消吗？')){
            return false;
        }
        hideLayer();
        $.post('{:U('cancel')}', {id:id}, function(data){
            if(data.status == 1){
                $('#ajaxlistboxform').submit();
                //updateList();
            }else{
                alert(data.info);
            }
        }, 'json');
    }
	//选择时间的控件点击事件不冒泡
	$(".btn-group .datepicker").click(function(e) {
        event.stopPropagation();
    });
	//点击翻页
	$(".f-pagesize").change(function(e){
		$("#pagesize").val($(this).val());
        $('#ajaxlistboxform').submit();
    });;
    $('.icheck input').change(function(){
		//判断时间控件
		if($(this).val()&&$(this).siblings('.datepicker').val()){
			$(".dropdown-text").text($(this).val()+'—'+$(this).siblings('.datepicker').val())
			$(this).parent().click();
		}else if($(this).hasClass('datepicker')){
			return;
		}
        $('#ajaxlistboxform').submit();
    });
    $.cookie('loadIndexUrl', window.location.href, {path:'/'});
    /*var sct = $(window).scrollTop();
     var affixtop = $('.affixelement.affix-top').offset().top;
     $(window).scroll(function(e) {
     if(sct > $(this).scrollTop()){
     //alert('上滚');
     $('.header-section').animate({top:'0px'},{queue:false});
     $('.sticky-header .main-content').removeClass('hiddentop');
     $('.affixelement.affix-top').animate({top:affxtop+'px',speed:50});
     }else{
     //alert('下滚');
     $('.sticky-header .main-content').addClass('hiddentop');
     $('.header-section').animate({top:'-80px'},{queue:false,speed:50});
     $('.affixelement.affix-top').animate({top:'0'});
     }
     sct = $(this).scrollTop();
     });*/
	 
	 
    //有关于页面的积分的一系列事件
    /*function sourceInput(e){
		//e.stopPropagation();
		//window.event.stopPropagation();
		//alert(e);
        //$(this).find(".sourceInput").attr("type",'number')
        if($(this).find(".sourceInput").css('display')!='block'){
            $(".sourcePanel").hide();
        }
        $(this).find(".sourcePanel").show();
        $(this).find(".hidden").removeClass("hidden");
    }*/
    //$("#masonrybox1").on("click",".checkbox-inline",sourceInput);
	//alert($('.checkbox-inline').length);
	
    //获得焦点的时候显示积分面板
    $("#masonrybox1").on("focusin",".single-row .sourcePanel",function(){
        var self=$(this);
        //window.setTimeout(function(){
        window.clearTimeout(window.time);
        self.show();
        //},10);
    });
    //失去焦点的时候隐藏积分面板
    $("#masonrybox1").on("blur",".single-row",function(){
        //$(this).find(".sourceInput").attr("type",'hidden')
        var self=$(this);
        window.time=setTimeout(function(){
            self.find(".sourcePanel").hide();
            //计算总分数
            var inte={};
            var num=0;
            self.parents('.panel-mission').find('.sourceInput').each(function(index,element){
                if(!($(this).attr('data-type') in inte)){
                    inte[$(this).attr('data-type')]=0
                }
                if($(this).val()==''){
                    num=$(this).attr('min')-0;
                }else{
                    num=$(this).val()-0;
                    num=num<$(this).attr('min')-0?$(this).attr('min')-0:num;
                    num=num>$(this).attr('max')-0?$(this).attr('max')-0:num;
                }
                inte[$(this).attr('data-type')]=inte[$(this).attr('data-type')]+num;
            });
            //加分
            $.each(inte,function(index,element){
                self.parents('.panel-mission').find("table input[value='"+index+"']").prev().val(element);
            });
            //console.log(inte);
        },100);
    });
	//将页面的表单替换成文字
	function textualization($obj){
		/*var $obj=$obj||$('.formBox');
		//当数据成功获取的时候将表单转化为纯文
		$obj.find('.form-control').each(function(index, element) {
			var val = $(this).val();
			$(this).replaceWith('<span style="color:#f60;">'+val+'</span>');
		});
		//当数据成功获取的时候将选择项转化为纯文本
		$obj.find('.single-row').each(function(index, element) {
			$(this).find('*').unbind();
			if($(this).find(".checked").length==0){
				$(this).parent().remove();
			}else{
				var input=$(this).find(".checked").removeAttr("class").remove();
			}
			//显示出可点击的框框
			if($(this).find('.sourcePanel').length){
				$(this).parent().addClass('sourceEdit');
			}
		});*/
		/*//当数据成功获取的时候将选择项转化为纯文本
		$('.formBox label.checkbox').each(function(index, element) {
			if($(this).find("input")[0].checked){
				$(".formBox hr").remove();
				var val=$(this).find("input").next().text();
				$(this).parent().replaceWith('<span>规则：</span><span style="color:#f60;">'+val+'</span>');
			}else{
				$(this).parent().remove();	
			};
			
		});*/
	}
	//改变显示的状态
    function setstate(state){
        reloadmasonry();
        $('#ajaxlistboxform').find('input[name="state"]').val(state);
        $('#ajaxlistboxform').submit();
    }
    function reloadmasonry(){
        $('#masonrybox1').masonry('destroy').empty();
        window.$maso=$('#masonrybox1').masonry({
            itemSelector: '.box',
            columnWidth: 0,
            isAnimated : true
        });
    }
    function updatemasonry(){
        if($('#masonrybox1').children().length > 0){
            $('#masonrybox1').masonry('destroy').empty();
        }
        window.$maso=$('#masonrybox1').masonry({
            itemSelector: '.box',
            columnWidth: 0,
            isAnimated : true
        });
		
    }
    updatemasonry();
    $('#missioncountbox').ajaxlist();
    $('#ajaxlistbox').ajaxlist({
        success:function(obj){
			updatemasonry();
            $('.schedulebox').ajaxlist({autoload:false});
			//文本化表单
			 textualization();
			//$(".btn-extended").click(extended);
			//$(".cover").click(extended);
			$(".panel-mission").click(extended).find(".panel-extended").click(function(e) {
                e.stopPropagation();
            });
			
            var html = $('#ajaxlistbox').children();
			$('#masonrybox1').masonry('destroy').empty();
            $newElems = html.appendTo('#masonrybox1');
			//console.log($newElems);
            $newElems.imagesLoaded(function(){
                $('#masonrybox1').masonry( 'appended', $newElems, true);
				$(window).trigger('resize');
				$("#masonrybox1 .checkbox-inline").click(function(e) {
					if($(this).find(".sourceInput").css('display')!='block'){
						$(".sourcePanel").hide();
					}
					$(this).find(".sourcePanel").show();
					$(this).find(".hidden").removeClass("hidden");
					e.stopPropagation();

				});
            });
        }
    });
	//展开收缩表格的控制窗口的方法
	function extended(){
		var judge=$(this).find(".panel-extended").css('display')=='none';
		$(".panel-extended").slideUp(100);
		$(".cover").hide();
		if(judge){
			$(this).find(".cover").show();
			$(this).find(".panel-extended").slideDown(100);
		}	
		$(".sourcePanel").hide();
	}
    $('.datepicker').datepicker({ dateFormat: 'yy-mm-dd' });
	
	$(window).trigger('resize');
</script>
</body></html><?php }?>